package bootstrap

import (
	"gitee.com/pangxianfei/library/config"
	"github.com/kataras/iris/v12"

	UserAppRoute "tmaic/app/user/routes"
	"tmaic/routes"
)

// 人事管理系统
func (s *App) UserApp() error {
	app := iris.New().SetName("UserApp")
	//注册资源及心跳路由
	route.Route(app)
	UserAppRoute.Route(app)
	s.UserRouteNameList(app, config.Instance.App.UserApp, config.Instance.AppPort.UserPort, config.Instance.AppNo.User)
	UserErr := s.SetAppConfig(app, config.Instance.AppPort.UserPort)
	_ = app.Build()
	return UserErr
}
